<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>YUNYECMS <?php echo YUNYECMS_VERSION; ?></title>
  <!-- Tell the browser to be responsive to screen width -->
  <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

  <!-- Font Awesome -->
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>plugins/fontawesome-free/css/all.min.css">
  <!-- Theme style -->
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>plugins/iCheck/all.css">
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>dist/css/AdminLTE.min.css">
  <!-- AdminLTE Skins. Choose a skin from the css/skins
       folder instead of downloading all of them to reduce the load. -->
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>dist/css/skins/_all-skins.min.css">
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>dist/css/admin.css">
  <link rel="stylesheet" href="<?php echo YUNYECMS_UI; ?>validator/dist/css/bootstrapValidator.css" />
  <script src="<?php echo YUNYECMS_UI; ?>plugins/jQuery/jquery-3.6.1.min.js"></script>
  <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
  <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
  <!--[if lt IE 9]>
  <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
  <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
  <![endif]-->
</head>

<body class="hold-transition rightbgcolor" onload="changefrmHeight()">
  <!-- Content Wrapper. Contains page content -->
  <div class="container-fluid" id="mainwrap">
    <!-- Main content -->
    <section class="content">
      <div class="row">
        <!-- left column -->
        <div class="col-md-12">
          <form id="form1" class="form-horizontal" method="post" action="<?php echo YUNYECMS_URLADM; ?>">
            <div class="card">
              <div class="card-header d-flex p-0">
                <h3 class="card-title p-3"><?php if ($yyact == "add") : ?> 增加会员组 <?php elseif ($yyact == "edit") : ?> 修改会员组 <?php endif ?></h3>
                <ul class="nav nav-pills ml-auto p-2">
                  <li class="nav-item" class="active"><a class="nav-link active" href="#tab_1_1" data-toggle="tab"><span class="lancnbox"><span class="lan-cn"></span></span> 中文版</a></li>
                  <li class="nav-item"><a class="nav-link" href="#tab_1_2" data-toggle="tab"><span class="lancnbox"><span class="lan-en"></span></span> English</a></li>
                </ul>
              </div><!-- /.card-header -->
              <div class="card-body">
                <div class="tab-content">
                  <div class="tab-pane active" id="tab_1_1">
                    <div class="card-body">
                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="title">会员组名称</label>
                        <div class="col-md-6">
                          <input type="text" class="form-control " id="groupname" name="groupname" <?php if (!empty($id)) : ?> value="<?php echo $rsinfo["groupname"]; ?>" <?php endif; ?> />
                        </div>
                      </div>
                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="title">默认</label>
                        <div class="col-md-6">
                          <input type="radio" name="isdefault" value="1" class="minimal-blue" <?php if (!empty($id)) {
                                                                                                if ($rsinfo['isdefault'] == 1) echo "checked";
                                                                                              } ?>> 是 &nbsp;
                          <input type="radio" name="isdefault" value="0" class="minimal-blue" <?php if (empty($id)) {
                                                                                                echo "checked";
                                                                                              } else {
                                                                                                if ($rsinfo["isdefault"] == 0) echo  "checked";
                                                                                              } ?>> 否
                        </div>
                      </div>
                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="title">游客</label>
                        <div class="col-md-6">
                          <input type="radio" name="isvisitor" value="1" class="minimal-blue" <?php if (!empty($id)) {
                                                                                                if ($rsinfo['isvisitor'] == 1) echo "checked";
                                                                                              } ?>> 是 &nbsp;
                          <input type="radio" name="isvisitor" value="0" class="minimal-blue" <?php if (empty($id)) {
                                                                                                echo "checked";
                                                                                              } else {
                                                                                                if ($rsinfo["isvisitor"] == 0) echo  "checked";
                                                                                              } ?>> 否
                        </div>
                      </div>
                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="description">简介</label>
                        <div class="col-md-6">
                          <textarea name="remark" id="remark" class="form-control " class="span5"><?php if (!empty($id)) echo $rsinfo["remark"]; ?> </textarea>
                        </div>
                      </div>


                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="title">排序</label>
                        <div class="col-md-6">
                          <?php if (empty($id)) : ?>
                            <input type="text" class="form-control " id="ordernum" name="ordernum" value="<?php echo $ordermax; ?>" />
                          <?php else : ?>
                            <input type="text" class="form-control " id="ordernum" name="ordernum" value="<?php echo $rsinfo["ordernum"]; ?>" />
                          <?php endif; ?>
                        </div>
                      </div>
                    </div>
                    <!-- /.box-body -->
                    <div class="card-footer">
                      <div class="row">
                        <div class="col-md-offset-3 col-md-9">
                          <button type="submit" class="btn bg-blue  btn-flat"><?php if ($yyact == "add") : ?> <i class="icon fa fa-plus"></i> 添 加 <?php elseif ($yyact == "edit") : ?> <i class="icon fa fa-edit"></i> 修 改 <?php endif ?></button> &nbsp; &nbsp;
                          <button type="reset" class="btn btn-default btn-flat"> <i class="fa fa-undo"></i> 重 置 </button>
                        </div>
                      </div>
                    </div>
                    <!-- /.box-footer -->
                  </div>
                  <div class="tab-pane" id="tab_1_2">
                    <div class="card-body">
                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="title">会员组名称(English)</label>
                        <div class="col-md-6">
                          <input type="text" class="form-control " id="groupname_en" name="groupname_en" <?php if (!empty($id)) : ?> value="<?php echo $rsinfo["groupname_en"]; ?>" <?php endif; ?> />
                        </div>
                      </div>

                      <div class="form-group row">
                        <label class="col-md-2 control-label" for="description">简介(English)</label>
                        <div class="col-md-6">
                          <textarea name="remark_en" id="remark_en" class="form-control " class="span5"><?php if (!empty($id)) echo $rsinfo["groupname_en"]; ?></textarea>
                        </div>
                      </div>
                    </div>
                    <div class="card-footer">
                      <div class="row">
                        <div class="col-md-offset-3 col-md-9">
                          <input name="yyact" type="hidden" value="<?php echo $yyact; ?>">
                          <input name="c" type="hidden" value="<?php echo ROUTE_C; ?>">
                          <input name="a" type="hidden" value="<?php echo ROUTE_A; ?>">
                          <?php echo $this->hashurl['svp']; ?>
                          <?php if (!empty($id)) : ?>
                            <input name="id" type="hidden" value="<?php echo $id; ?>">
                          <?php endif ?>
                          <button type="submit" class="btn bg-blue  btn-flat"><?php if ($yyact == "add") : ?> <i class="icon fa fa-plus"></i> 添 加 <?php elseif ($yyact == "edit") : ?> <i class="icon fa fa-edit"></i> 修 改 <?php endif ?></button> &nbsp; &nbsp;
                          <button type="reset" class="btn btn-default btn-flat"> <i class="fa fa-undo"></i> 重 置 </button>
                        </div>
                      </div>
                    </div>
                  </div>

                </div>

              </div><!-- /.card-body -->
            </div>
            <!--BEGIN TABS-->


            <!--END TABS-->
          </form>
        </div>
        <!--/.col (left) -->
      </div>
      <!-- /.row -->
    </section>
    <!-- /.content -->
  </div>
  <!-- /.content-wrapper -->
  <?php require tpl_adm('foot'); ?>

  <!-- jQuery 2.2.3 -->
  <script src="<?php echo YUNYECMS_UI; ?>plugins/jQuery/jquery-3.6.1.min.js"></script>
  <!-- Bootstrap 3.3.6 -->
  <script src="<?php echo YUNYECMS_UI; ?>bootstrap/js/bootstrap.min.js"></script>
  <!-- FastClick -->
  <!-- AdminLTE for demo purposes -->
  <script src="<?php echo YUNYECMS_UI; ?>dist/js/admin.js"></script>
  <script src="<?php echo YUNYECMS_UI; ?>plugins/iCheck/icheck.min.js"></script>

  <script type="text/javascript" src="<?php echo YUNYECMS_UI; ?>validator/dist/js/bootstrapValidator.js"></script>
  <script>
    $(function() {
      //iCheck for checkbox and radio inputs
      $('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({
        checkboxClass: 'icheckbox_minimal-blue',
        radioClass: 'iradio_minimal-blue'
      });
      //Red color scheme for iCheck
      $('input[type="checkbox"].minimal-red, input[type="radio"].minimal-red').iCheck({
        checkboxClass: 'icheckbox_minimal-red',
        radioClass: 'iradio_minimal-red'
      });
      //Flat red color scheme for iCheck
      $('input[type="checkbox"].flat-blue, input[type="radio"].flat-blue').iCheck({
        checkboxClass: 'icheckbox_flat-blue',
        radioClass: 'iradio_flat-blue'
      });
    });
  </script>
  <script type="text/javascript">
    $(document).ready(function() {
      $('#defaultForm').bootstrapValidator({
        message: 'This value is not valid',
        //        live: 'disabled',
        feedbackIcons: {
          valid: 'glyphicon glyphicon-ok',
          invalid: 'glyphicon glyphicon-remove',
          validating: 'glyphicon glyphicon-refresh'
        },
        fields: {
          title: {
            message: '栏目名称是无效的',
            validators: {
              notEmpty: {
                message: '栏目名称必需填写'
              },
              /* remote: {
                   url: 'user_add.php',
                   message: '部门名是不可用的'
               },*/
            }
          },
        }
      });
    });
  </script>
  <script language="javascript" type="text/javascript">
    $(function() {
      var navudinfo = "<?php echo $parnav; ?>";
      $('.breadcrumb', window.parent.document).children('#homeitem').nextAll().remove();
      $('.breadcrumb', window.parent.document).children('#homeitem').after(navudinfo);
    });
  </script>

  <script>
    $(function() {
      //iCheck for checkbox and radio inputs
      $('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({
        checkboxClass: 'icheckbox_minimal-blue',
        radioClass: 'iradio_minimal-blue'
      });
      //Red color scheme for iCheck
      $('input[type="checkbox"].minimal-red, input[type="radio"].minimal-red').iCheck({
        checkboxClass: 'icheckbox_minimal-red',
        radioClass: 'iradio_minimal-red'
      });
      $('input[type="checkbox"].minimal-blue, input[type="radio"].minimal-blue').iCheck({
        checkboxClass: 'icheckbox_minimal-blue',
        radioClass: 'iradio_minimal-blue'
      });
      //Flat red color scheme for iCheck
      $('input[type="checkbox"].flat-blue, input[type="radio"].flat-blue').iCheck({
        checkboxClass: 'icheckbox_flat-blue',
        radioClass: 'iradio_flat-blue'
      });
    });
  </script>


</body>

</html>